
public class ShortCircuit {
    static boolean test1(int var) {
        System.out.println("test1{" + var + "}");
        System.out.println("test1: " + (var < 1));
        return var < 1;
    }

    static boolean test2(int var) {
        System.out.println("test2{" + var + "}");
        System.out.println("test2: " + (var < 2));
        return var < 2;
    }

    static boolean test3(int var) {
        System.out.println("test3{" + var + "}");
        System.out.println("test3: " + (var < 3));
        return var < 3;
    }

    public static void main(String[] args) {
        boolean b = test1(0) && test2(2) && test3(3);
        System.out.println("b: " + b);
    }
}
